package cn.sczhyt.modules.sys.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.sczhyt.common.utils.PageUtils;
import cn.sczhyt.common.utils.Query;

import cn.sczhyt.modules.sys.dao.SysScoreDao;
import cn.sczhyt.modules.sys.entity.SysScoreEntity;
import cn.sczhyt.modules.sys.service.SysScoreService;


@Service("sysScoreService")
public class SysScoreServiceImpl extends ServiceImpl<SysScoreDao, SysScoreEntity> implements SysScoreService {
    @Autowired
    private SysScoreEntity sysScoreEntity;


    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        String name = (String) params.get("name");
        if (name==null)
            name="";
        System.out.println(name);
        IPage<SysScoreEntity> page = this.page(
                new Query<SysScoreEntity>().getPage(params),
                new QueryWrapper<SysScoreEntity>().like("name",name)
        );

        return new PageUtils(page);
    }

}
